﻿#pragma once
#include "Singleton.h"
#include <Windows.h>
#include "Vector3.h"

enum class PlayerType
{
	none,
	enemy,
	oneself
};

struct Box
{
	float x;
	float y;
	float width;
	float height;
	float centerX;
	float centerY;
};

class Player
{
public:
	Player(uintptr_t addres);
	~Player();

	// 基址
	uintptr_t base;

	// 骨骼矩阵地址
	uintptr_t skeletonMatrixAddr;
	// 骨骼数组地址
	uintptr_t skeletonArrayAddr;

	// 内存中读取的坐标
	Vector3 origin;
	// 距离
	float distance;
	// 透视方框尺寸信息
	Box box;
	// 血量
	float hp;
	// 是否是最佳自瞄目标
	bool bestAimTarget = false;
	// 类型
	PlayerType type = PlayerType::none;
	// 重新去内存中读数据更新
	void update();
};
